{{>header}}

<div class="top100 main">
    {{#if users}}
        <table cellpadding="0" cellspacing="0">
            <tr>
                <th width="30">#</th>
                <th colspan="2">用户名</th>
                <th width="60">积分</th>
                <th width="80">主题数</th>
                <th width="80">评论数</th>
            </tr>
            {{#each users}}
                <tr>
                    <th>{{@index}}</th>
                    <td width="30"><a href="/user/{{_id}}" class="img"><img src="/uploads/{{avatar}}" alt=""></a></td>
                    <td><a href="/user/{{_id}}">{{name}}</a></td>
                    <td>{{score}}</td>
                    <td>{{#with (lookup ../postCounts @index)}}{{.}}{{/with}}</td>
                    <td>{{#with (lookup ../commentCounts @index)}}{{.}}{{/with}}</td>
                </tr>
            {{/each}}
        </table>
    {{else}}
        <div class="noData">没有数据。。。</div>
    {{/if}}

</div>

{{>homeSide}}